Ext.define('Moodle.model.User', {
    extend: 'Ext.data.Model',
    config: {
    //identifier: 'uuid',
        idProperty: 'userid',
        fields: [
            {name: "userid", type: "auto" }, 
            {name: "username", type: "string"},
            {name: "firstname", type: "string"},
            {name: "lastname", type: "string"},
            {name: "password", type: "string"},
            {name: "userpictureurl", type: "string"},
            {name: "token", type: "string"}            
            
        ],  
        	//hasMany: {model: 'Course', name: 'enrolledcourses'},      
            proxy: {
            type: 'localstorage',
            id  : 'moodle-store'
        },
    }
    
});